package com.pandora.framework.constant;

/**
 * 接口服务常量
 * 
 * @author JingChenglong 2017/12/20 14:11
 *
 */
public class ServiceConstants {

	/** 接口状态 */
	public static final String SERVICE_STATUS_RUNNING = "1";
	public static final String SERVICE_STATUS_STOP = "2";

	/** 签名方式 */
	public static final String SERVICE_SIGNTYPE_MD5 = "1";
	public static final String SERVICE_SIGNTYPE_HMACSHA1 = "2";

	/** 是否为上传文件接口 */
	public static final String UP_FLAG_TRUE = "1";
	public static final String UP_FLAG_FALSE = "2";

	/** 是否需要通行证 */
	public static final String ACCESS_FLAG_TRUE = "1";
	public static final String ACCESS_FLAG_FALSE = "0";
	/** 数据格式 */
	public static final String XML = "xml";
	public static final String JSON = "json";

	/** 请求方法 */
	public static final String REQUEST_METHOD_GET = "GET";
	public static final String REQUEST_METHOD_POST = "POST";

	/** 请求内容最大长度限制 */
	public static final int CONTENT_LENGTH = 102400;// 100KB
	public static final int CONTENT_LENGTH_MAX = 1073741824;// 1GB

	/** 接口服务类型 */
	public static final String SERVICETYPE_HTTP = "1";// HTTP
	public static final String SERVICETYPE_OTHER = "2";// 其他

	/** 系统配置文件key */
	public static final String _ACCESS_ID = "_ACCESS_ID";
	public static final String _ACCESS_KEY = "_ACCESS_KEY";

	/** 请求时参数key */
	public static final String REQCONTENTMD5 = "reqcontentmd5";// 请求题内容的MD5签名值
	public static final String REQCONTENTHMACSHA1 = "reqcontenthmacsha1";// 请求题内容的HMAC1签名值
	public static final String SIGN = "sign";// 请求签名
	public static final String ACCESSID = "accessid";// ACCESSID
	public static final String REQUEST_TYPE = "requestType";// 请求服务接口类型
	public static final String REQLENGTH = "reqlength";// 请求体长度
	public static final String FORMAT = "format";// 请求内容格式
	public static final String REQUEST_ROOT = "request";// 请求体内容报文根节点
	public static final String COMMON = "common";// 请求体内容通用信息
	public static final String CONTENT = "content";// 请求体中存储请求体参数信息
	public static final String ACTION = "action";// 请求体内容中存储action的key
	public static final String REQTIME = "reqtime";// 请求体内容common中存储请求时间的key
}